<%--
  Created by IntelliJ IDEA.
  User: ASUS
  Date: 2021/1/25
  Time: 19:10
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fmt" uri ="http://java.sun.com/jsp/jstl/fmt"%>
<html>
<head>
    <title>修改</title>
</head>
<body>
<h1>修改</h1>
<form action="/update" method="post">
    <input type="hidden" name="id" value="${bill.id}">
    <p>
        类型：
        <c:forEach items="${types}" var="type">
            <input type="radio" name="typeid" value="${type.id}" ${bill.id==type.id?"checked":""}>${type.name}
        </c:forEach>
    </p>
    <p>
        标题：<input type="text" name="title" value="${bill.title}">
    </p>
    <p>

        日期：<input type="text" name="billtime" value="<fmt:formatDate value="${bill.billtime}" pattern="yyyy/MM/dd"></fmt:formatDate>">
        金额：<input type="text" name="price" value="${bill.price}">
    </p>
    <p>
        说明：<textarea name="billexplain" cols="40" rows="4">${bill.billexplain}</textarea>
    </p>
    <input type="reset" value="重置">
    <input type="submit" value="保存">
</form>
</body>
</html>
